package com.example.studentaihouduan.service.Serviceimpl;


import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.example.studentaihouduan.Mapper.PatientRegistrationMapper;
import com.example.studentaihouduan.entity.PatientRegistration;
import com.example.studentaihouduan.service.PatientRegistrationService;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class PatientRegistrationServiceImpl extends ServiceImpl<PatientRegistrationMapper, PatientRegistration>
        implements PatientRegistrationService {

    @Override
    public List<PatientRegistration> getAllRegistrations() {
        return list();
    }

    @Override
    public PatientRegistration getRegistrationById(Integer id) {
        return getById(id);
    }

    @Override
    public void saveRegistration(PatientRegistration registration) {
        save(registration);
    }

    @Override
    public void updateRegistration(PatientRegistration registration) {
        updateById(registration);
    }

    @Override
    public void deleteRegistration(Integer id) {
        removeById(id);
    }
}
